.dark-mode {
    .form-control:focus {
        background-color: inherit;
        box-shadow: none;
        border-color: inherit;
    }

    .form-element-file,
    .form-element-image,
    .form-element-images {
        .form-element-helptext {
            background: $dark-bg-color;
        }
    }

    .input-group-text {
        background-color: lighten($dark-bg-color, 5%);
    }

    .form-element-files__info {
        background: darken($dark-bg-color, 5%);
    }

    .form-element-files {

        &__file {
            color: inherit;
            background: $dark-bg-color;
        }

        &__item {
            border-color: $gray-600;
            border-radius: 0.25rem;
        }
    }

    textarea {
        background-color: inherit;
        color: inherit;
    }

    .form-control:disabled, .form-control[readonly] {
        color: $gray-400 !important;
        background-color: lighten($dark-bg-color, 15%) !important;
    }
}

.noresize {
    resize: none;
}

textarea {
    padding: 0.5rem;
    outline-style: none;
    border-radius: 0.25rem;
}

.form-control::placeholder {
    color: $gray-500;
}

.filter-badge {
    a {
        color: $white;
        font-size: 1.1em;
        padding: 0.1em 0.5em;
        margin-right: -0.5em;
    }
}

.form-elements {
}

$errors-text-color: darken($danger, 10%);
$errors-bg-color: $gray-100;
$arrow-size: 6px;

.form-element-errors {
    color: $danger;
    font-size: 13px;
}

.form-element-helptext {
    color: $gray-600;
    font-style: italic;
    padding: 0 1.25rem 0.5rem;
}

.form-element-required {
    color: $danger;
    vertical-align: baseline;
}

//.form-element-checkbox {
//}
//
//.form-element-column {
//}
//
//.form-element-columns {
//}
//
//.form-element-date {
//}
//
//.form-element-time {
//}
//
//.form-element-timestamp {
//}
//
//.form-element-dependentselect {
//}
//
//.form-element-file {
//}
//
//.form-element-image {
//}
//
//.form-element-images {
//}
//
//.form-element-multiselect {
//}
//
//.form-element-select {
//}

.form-element-multiselect,
.form-element-select {
    &.has-error {
        .select2-selection {
            border-color: $danger !important;
        }
    }
}

//.form-element-number {
//}
//
//.form-element-password {
//}
//
//.form-element-radio {
//}
//
//.form-element-text {
//}
//
//.form-element-textaddon {
//}
//
//.form-element-textarea {
//}
//
//.form-element-upload {
//}
//
//.form-element-wysiwyg {
//}

.form-element-files {
    &.dropzone {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
    }
}

.form-element-checkbox,
.form-element-file,
.form-element-image,
.form-element-images,
.form-element-textarea,
.form-element-wysiwyg {
    .form-element-helptext {
        display: block;
    }
}

.form-element-file,
.form-element-image,
.form-element-images {
    .form-element-helptext {
        background: $gray-100;
        padding: 3px 6px;
    }
}

.form-element-file,
.form-element-image,
.form-element-images,
.form-element-textarea,
.form-element-wysiwyg {
    .form-element-helptext {
        margin-bottom: 10px;
    }
}

.form-element-files__item {
    max-width: 100%;
    min-width: 260px;
    border: 1px solid $gray-400;
    border-radius: 0.25rem;
    margin-bottom: 10px;
    margin-right: 10px;
    padding: 3px;

    @media (max-width: 667px) {
        max-width: 50%;
    }
    @media (max-width: 576px) {
        max-width: 100%;
    }
}

.form-element-files__image,
.form-element-files__info,
.form-element-files__size {
    display: block;
}

a.form-element-files__image {
    align-items: center;
    width: 100%;
    justify-content: center;
    display: flex;
}

.form-element-files__info {
    padding: 10px 0.3rem;
    background: $gray-100;
    height: 50px;
}

.form-element-files__file,
.form-element-files__image {
    text-align: center;
    padding: 0;
}

.form-element-files__file {
    font-size: 65px;
    color: $secondary;
    background: $white;
    padding: 20px 10px;
}

.form-element-files__image {
    height: 200px;
    overflow: hidden;

    > img {
        width: auto;
        max-height: 100%;
        object-fit: cover;
    }
}

//.form-element-files__close {
//}

.form-element-date,
.form-element-daterange,
.form-element-time,
.form-element-timestamp {
    .input-group {
        width: 250px;
    }
}

.input-group-addon .fa-calendar,
.input-group-addon .fa-clock-o {
    cursor: pointer;
}

.datepicker td,
.datepicker th {
    width: initial;
}
